<?php

namespace app\index\controller;
use \think\Request;
use \think\Session;
use \think\Controller;
use \think\View;
use \think\Db;

class center{

	//个人中心
	public function centerIndex(){
		$request = Request::instance();
		$uid = $request->param('uid');
		//获取用户详细信息
		$user_info = Db::name('user')->field('username,userpic,introduction')->where('uid','eq',$uid)->select();
		//var_dump($user_info);
		return $user_info;
	}
	//编辑个人信息
	public function editUser(){
		$request = Request::instance();
		$uid = $request->param('uid');
		$user_info = Db::name('user')->select();

		//var_dump($user_info);
		return $user_info;

	}

	//修改个人信息
	public function editAdd(){
		$reuqest = Request::instance();

		$username = $request->param('username');
		$sex = $request->param('sex');
		$introduction = $request->param('introduction');
		$birth = $request->param('birth');
		$background = $request->param('background');
		$cid = $request->param('cid');
		$cname = Db::name('company')->field('cname')->find();


	}
}